<?php 
$this->headScript()->appendFile(_STATIC_HTTP . '/admin/js/collect.js?item=form');
$this->headScript()->appendFile(_STATIC_HTTP . '/jquery/json2.js');
$this->headLink()->prependStylesheet(_STATIC_HTTP . '/admin/css/collect.css');
?>
<form action="<?php echo $this->url('collection/collect/item', array('id' => $this->row->getId()));?>" method="post" id="form">
<?php echo $this->form()->hidden('referer', $this->referer);?>
<?php echo $this->form()->hidden('id', $this->row->getId()) . "\n";?>
<div class="body">
	<table class="form">
		<tr>
			<th style="width:320px"><?php echo $this->language('ITEM COLLECT');?>:</th>
			<th><?php echo $this->language('PROCESSING');?></th>
		</tr>
		<tr>
			<td style="padding:0;">
				<div class="sbutton center">
					<button type="button" name="start" id="startButton" value="start" style="margin:0;" onclick="return collect.doStart();"><?php echo $this->language('START TO COLLECT');?>»</button>
					<button type="button" name="stop" id="stopButton" value="stop" style="margin:0;" onclick="return collect.doStop();" class="hidden"><?php echo $this->language('STOP');?>»</button>
				</div>
				<div id="left">
					<table class="no-border form">
						<tr>
							<td>
								<fieldset style="margin:0;padding:1px 0;">
								<legend style="margin:0 5px;">&nbsp;&nbsp;<?php echo $this->language('COLLECT OPTIONS');?>&nbsp;&nbsp;</legend>
								<ul>
									<li>
										<?php echo $this->form()->checkbox('setting[auto_import_special]', '1', array('id' => 'autoImportSpecial', 'checked' => 'checked'));?>
										<label class="for-checkbox" for="autoImportSpecial"><?php echo $this->language('Import SPECIALS into database Automatically');?>.</label>
										<code style="color:red;padding-left:1.8em;"><?php echo $this->language('Robot will save the collected SPECIALS as logs, and then save SPECIALS to your Picture System Automatically');?>.</code>
									</li>
									<li>
										<?php echo $this->form()->checkbox('setting[auto_import_photo]', '1', array('id' => 'autoImportPhoto', 'checked' => 'checked'));?>
										<label class="for-checkbox" for="autoImportPhoto"><?php echo $this->language('Import PHOTOS into database Automatically');?>.</label>
										<code style="color:red;padding-left:1.8em;"><?php echo $this->language('As above, save PHOTOS to your Picture System Automatically');?>.</code>
									</li>
									<li>
										<?php echo $this->form()->checkbox('setting[from_last_position]', '1', array('id' => 'fromLastPosition', 'checked' => 'checked', 'onclick' => 'collect.resetParams();'));?>
										<label class="for-checkbox" for="fromLastPosition"><?php echo $this->language('Start from Last Collection Position');?>.</label>
										<code style="color:red;padding-left:1.8em;"><?php echo $this->language('It will start from LAST position, and Ignores collected pages.');?>.</code>
									</li>
									<li>
										<?php echo $this->form()->checkbox('setting[ignore_error]', '1', array('id' => 'ignoreError', 'checked' => 'checked'));?>
										<label class="for-checkbox" for="ignoreError"><?php echo $this->language('Ignore errors');?>.</label>
										<code style="color:red;padding-left:1.8em;"><?php echo $this->language('If error occurred, ignores it and the progressing will NOT stop.');?>.</code>
									</li>
									<li><hr/></li>
									<li>
										<strong><?php echo $this->language('SAVE SPECIAL TO');?></strong>:
										<?php echo $this->partial('picture/_inc/categoryCheckbox.phtml', array('name' => 'category_id[]', 'selected' => $this->categoryList, 'type' => 'checkbox'));?>
									</li>
								</ul>
								</fieldset>
							</td>
						</tr>
					</table>
				</div>
			</td>
			<td class="nohover">
				<div id="_processTable">
					<table class="no-border list" id="processTable"></table>
				</div>
			</td>
		</tr>
		<tr>
			<th></th>
			<th class="right">MESSAGE: <strong id="_processStat_message">0</strong>; ERROR: <strong id="_processStat_error">0</strong></th>
		</tr>
	</table>
</div>
</form>
